]> dgit.raspbian.org Git - gnome-shell.git/commitdiff
Disable XDND when running as a wayland compositor
authorGiovanni Campagna <gcampagn@redhat.com>
Wed, 11 Sep 2013 15:50:18 +0000 (17:50 +0200)
committerGiovanni Campagna <gcampagn@redhat.com>
Thu, 12 Sep 2013 08:34:25 +0000 (10:34 +0200)
We can't do xdnd on wayland easily, so let's disable this for 3.10

https://bugzilla.gnome.org/show_bug.cgi?id=707467

js/ui/xdndHandler.js
src/gnome-shell-plugin.c

index 68da0bf24d18b1085e7c06d03e47e8a9d9f105d3..da6c18ff9755c0130ed00cdd4dba4f5d6adb634c 100644 (file)
@@ -3,6 +3,7 @@
 const Clutter = imports.gi.Clutter;
 const Lang = imports.lang;
 const Main = imports.ui.main;
+const Meta = imports.gi.Meta;
 const Shell = imports.gi.Shell;
 const Signals = imports.signals;
 const DND = imports.ui.dnd;
@@ -20,7 +21,8 @@ const XdndHandler = new Lang.Class({
         Main.uiGroup.add_actor(this._dummy);
         this._dummy.hide();
 
-        global.init_xdnd();
+        if (!Meta.is_wayland_compositor())
+            global.init_xdnd();
 
         global.connect('xdnd-enter', Lang.bind(this, this._onEnter));
         global.connect('xdnd-position-changed', Lang.bind(this, this._onPositionChanged));
index 631e373233818dea23237133307e5914c57fb789..0c41c0053fab96746849431ae1d6419eea085234 100644 (file)
@@ -35,6 +35,7 @@
 #include <gjs/gjs.h>
 #include <meta/display.h>
 #include <meta/meta-plugin.h>
+#include <meta/util.h>
 
 #include "shell-global-private.h"
 #include "shell-perf-log.h"
@@ -343,8 +344,13 @@ gnome_shell_plugin_xevent_filter (MetaPlugin *plugin,
     }
 #endif
 
+#ifdef HAVE_WAYLAND
+  if (meta_is_wayland_compositor ())
+    return FALSE;
+#endif
+
   /*
-   * Pass the event to shell-global
+   * Pass the event to shell-global for XDND
    */
   if (_shell_global_check_xdnd_event (shell_plugin->global, xev))
     return TRUE;